#pragma once
#include <boost/shared_ptr.hpp>
#include "TypeDefs.h"
class IGame;
class IGameScreen;
typedef boost::shared_ptr<IGameScreen> GameScreenPtr;
class IScreenManager
{
public:
	//Dump open screens to console
	virtual void DumpScreensToSTD() = 0;
	//Initializes the screenmanager
	virtual bool Init(IGame *pGame) = 0;
	//Adds a screen after the base screen if pScreenBase is NULL the screen is added as the topmost screen
	virtual bool AddScreenAfter(GameScreenPtr spScreen, IGameScreen *pScreenBase = NULL) = 0;
	//Adds a screen before the base screen if pScreenBase is NULL the screen is added as the bottom screen
	virtual bool AddScreenBefore(GameScreenPtr spScreen, IGameScreen *pScreenBase = NULL) = 0;
	//Request a screen to be removed
	virtual void RequestScreenRemoval(IGameScreen *pScreen) = 0;
	//Instantly remove a screen
	virtual void RemoveScreen(IGameScreen *pScreen) = 0;
	//Returns the number of screens
	virtual uint GetScreenCount() = 0;
	//Gets the screen at a position
	virtual GameScreenPtr GetScreenAt(int index) = 0;
	//Gets the topmost screen
	virtual GameScreenPtr GetTopScreen() = 0;
	//Gets the bottom screen
	virtual GameScreenPtr GetBaseScreen() = 0;
	//Screen manager cleanup
	virtual void Cleanup() = 0;
	//Input Handlers
	virtual void OnKeyPress(uint key) = 0;
	virtual void OnKeyRelease(uint key) = 0;
	virtual uint GetKeyMod() = 0;

	//Updates all the screens
	virtual void Update() = 0;
	//Renders all the screens
	virtual void Render() = 0;
};